/*
 * ModelView.cpp
 *
 *  Created on: 20-dec.-2013
 *      Author: Axel
 */

#include <ModelView.h>

ModelView::ModelView(float x, float y, float z) {
	location.x = x;
	location.y = y;
	location.z = z;

}

ModelView::~ModelView() {

}

void ModelView::move(float x, float y, float z) {
	location.x += x;
	location.y += y;
	location.z += z;
}

Vector3f ModelView::toWorld(Vector3f mesh) {
	Vector3f next;

	Matrix4f model;
	model.m[0][3] = location.x;
	model.m[1][3] = location.y;
	model.m[2][3] = location.z;

	next = (model.matVector(mesh));

	return next;
}

Vector4f ModelView::getLocation() {
	return location;
}

